package com.santoker.baseservice;

import lombok.Getter;

@Getter
public enum ApiResponseCode {

    WECHAT_AUTH_FAILURE("401", "微信授权失败"),

    SUCCESS("A00001", "success"),
    PARAM_ILLEGAL("A00002", "请输入正确格式数据"),
    REGISTER_DUPLICATED_PHONE("A00003", "手机号码已被注册"),
    REGISTER_DUPLICATED_EMAIL("A00004", "邮箱已被注册"),
    REGISTER_DUPLICATED_NICKNAME("A00005", "昵称已存在"),
    REGISTER_FAILURE("A00006", "注册失败"),
    SEND_MOBILE_CODE_FAILURE("A00007", "发送手机验证码失败"),
    SEND_EMAIL_CODE_FAILURE("A00008", "发送邮箱验证码失败"),
    CODE_EXPIRED("A00009", "验证码已过期"),


    USER_RECORD_NOT_EXIST("B00000", "用户记录不存在"),

    NOT_AUTHORIZED("L00000", "token无效"),
    PASSWORD_WRONG("L00001", "密码错误"),
    USER_NOT_EXIST("L00002", "用户不存在"),
    CAPTCHA_WRONG("L00004", "验证码错误"),
    OPENID_EXISTED("L00005", "OPENID已存在"),
    ACCOUNT_NOT_EXIST("L00006", "账号不存在"),
    WX_BIND_FAILURE("L0007", "微信绑定失败"),
    WX_UNBIND_FAILURE("L00008", "微信解绑失败"),
    USER_UPDATE_FAILURE("L00009", "用户更新失败"),
    MOBILE_NOT_EXIST("L00010", "手机号不存在"),
    EMAIL_NOT_EXIST("L00011", "邮箱不存在"),
    EMAIL_EXIST("L00012", "邮箱已存在"),
    MOBILE_EXIST("L00013", "手机号已存在"),
    RESET_PASSWORD_FAILED("L00014", "重置密码失败"),
    WX_BIND_ACCOUNT("L00015", "该微信已绑定账号，请勿重复绑定"),
    MOBILE_REGISTER("L00016", "该手机号已注册，请用手机号登录"),
    EMAIL_REGISTER("L00017", "该邮箱已注册，请用邮箱登录"),
    ACCOUNT_REGISTER("L00018", "该账号已注册，请用账号登录"),
    EMAIL_NOT_REGISTER("L00019", "该邮箱未注册，请绑定已注册邮箱"),
    MOBILE_NOT_REGISTER("L00020", "该手机号未注册，请绑定已注册手机号"),
    ACCOUNT_NOT_REGISTER("L00021", "该账号未注册，请绑定已注册账号"),
    EMAIL_BIND("L00022", "用户已绑定邮箱，请勿重复绑定"),
    MOBILE_BIND("L00023", "用户已绑定手机号，请勿重复绑定"),

    SYSTEM_ERROR("E00001", "系统错误"),
    NOT_LOGIN("E00001", "未登录"),
    BATCH_SETTING_FAILURE("E00002", "批量设置失败"),
    BATCH_DEL_FAILURE("E00003", "批量删除失败"),

    NOT_BIND_ACCOUNT("F00001", "微信授权未绑定账号，跳转绑定账号页面"),

    FACTORY_UPGRADE_FIRMWARE("G00001", "设备需要返厂刷新固件"),
    FIRMWARE_LATEST("G00002", "设备版本已是最新版"),

    ;

    private String code;
    private String msg;

    ApiResponseCode(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

}
